﻿#include "netcomm.h"

#include "../../include/itframework.h"
#include "../../include/itlogger.h"
#include "../../include/itcommon.h"
extern "C" __declspec(dllexport) ITModelBase* GetInstance(ITFramework *pFrame)
{
    NetComm *pNetComm = NetComm::GetInstance();
    pNetComm->SetFramework(pFrame);
    return dynamic_cast<ITModelBase*>(pNetComm);
}

NetComm::NetComm()
{
    qDebug() << "NetComm::NetComm()";
}

NetComm::~NetComm()
{
    qDebug() << "NetComm::~NetComm()";
}

void NetComm::SetFramework(ITFramework *pFrm)
{
    m_pFramework = pFrm;
    m_pFramework->GetLogger(&m_pLogger);
    m_pFramework->GetCommon(&m_pcommon);
}

T_BEGIN_MAP(NetComm)
    T_HANDLER(Public_NetComm_SendRobotCoreBehaviour_CMD_ID,sendBehaviour,TPNetComm_SendRobotCoreBehaviour,TObject)
T_END_MAP

void NetComm::sendBehaviour(TPNetComm_SendRobotCoreBehaviour *pInArgs, TObject *pOutArgs)
{
    qDebug() << "NetComm::sendBehaviour" << pInArgs->wx << pInArgs->ndelay;
}


